package cn.stylefeng.guns.modular.business.custom.enums;

public enum OrderAbnormalTypeEnum {

    PICK(1, "提车超时"),
    VERIFY(2, "验车超时"),
    TRANSPORT(3, "发车超时"),
    DELIVERY(4, "交付超时"),
    TRANSFER(5, "中转发车超时");

    OrderAbnormalTypeEnum(int type, String desc) {
        this.type = type;
        this.desc = desc;
    }

    public int type;

    public String desc;

    public static boolean valid(Integer type) {
        if (type == null) {
            return false;
        }
        OrderAbnormalTypeEnum[] pts = OrderAbnormalTypeEnum.values();
        for (OrderAbnormalTypeEnum pt : pts) {
            if (type == pt.type) {
                return true;
            }
        }
        return false;
    }
}
